package sorter;

import java.rmi.Naming;
import sorter.SortFactory;

public class SortServer {
	
	private static final String HOST = "localhost";
	
	public SortServer() {
		super();
	}
	
	public void main(String args[]) {
		try {
			SortFactory sf = new SortFactory();
			String rmiObjectName = "rmi://" + HOST + "/sort";
			System.out.println("Attempting to bind SortFactory");
			Naming.rebind(rmiObjectName, sf);
			System.out.println("Binding succesfull...\n");
		} catch (Exception e) {
			System.err.println("Exception:");
			e.printStackTrace();
		}
	}
	
}
